package com.key.service;

import com.key.common.dto.RepairFormFindDTO;
import com.key.common.vo.RepairFormVO;
import com.key.entity.RepairForm;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;

import java.util.List;
import java.util.Map;

/**
 * @author wei
 * @create 2023-02-22 9:23
 */
public interface RepairFormService {

    /**
     * 添加维修单
     * @param repairForm
     * @return
     */
    boolean addRepairForm(RepairForm repairForm);

    /**
     * 删除维修单
     * @param rfNo
     * @return
     */
    boolean removeRepairForm(String rfNo);

    /**
     * 修改维修单
     * @param repairForm
     * @return
     */
    boolean editRepairForm(RepairForm repairForm);

    /**
     * 查询维修清单
     * @param repairFormFindDTO
     * @return
     */
    Map<String, Object> findRepairForm(RepairFormFindDTO repairFormFindDTO);

    /**
     * 根据单号查询维修清单的信息，以及清单下的资产
     * @param rfNo
     * @return
     */
    RepairFormVO findRepairFormInfoByRfNo(String rfNo);

    boolean setAssetsState(String rfNo, Integer assetsState, List<Long> assetsIds);

    HSSFWorkbook getWorkBook();
}
